1. Field of the Invention
The present invention relates to an image processing device and an image processing program for processing a plurality of color signals formed of a plurality of color components to produce image signals for a prescribed image.
2. Description of Related Art
In recent years, color printers of the type that eject multiple colors of ink from the print head, commonly known as inkjet printers, have become widely popularized as a computer output device. These inkjet printers are widely used to print images that have been processed by a computer or the like in multiple colors and multiple gradations. Gradations corresponding to inputted density data are rendered by controlling the rate of dot generation within a particular region.
One method based on this line of thinking is called a bi-level error-diffusion halftone method. This method controls the generation of dots for each pixel such that the density error generated over the entire image is drastically reduced. To accomplish this, error generated at each pixel caused by a disparity between the intended tone represented by the inputted density data and the actual density represented by the existence of dots is spread to neighboring unprocessed pixels. In this method, whether or not to form a dot at each pixel is determined based on correction data that incorporates the error diffused in the inputted density data.
In recent years, various technologies other than the error-diffusion method have been proposed for enhancing the gradient depiction of inkjet printers. One such technology is a printing device and method employing light and dark ink, such as those disclosed in U.S. Pat. Nos. 6,089,691 and 6,099,105. This printing device uses high- and low-density inks for the same colors and controls the ejection of both shades of ink to achieve excellent gradation in the printing process.
Another printing device described in Japanese Unexamined Patent Application Publication No. SHO-59-201864 has been proposed as a method for rendering multiple gradations. This device can vary the density per unit surface area in multiple gradations by forming two types of dots differing in ink concentration and dot diameter. This printing device forms one pixel using four dots and is capable of printing images in multiple levels of density by varying the generated frequency of high- and low-density dots within each pixel.
Both of the methods proposed in the U.S. Pat. Nos. 6,089,691 and 6,099,105 and in the Japanese Unexamined Patent Application Publication No. SHO-59-201864 render multiple tones of each color hue not by bi-level method of specifying whether each color dot is on or off, but by a three-level or multi-level method using light and dark dots (variable-density dots).
FIG. 1 is a block diagram showing an outline of the processes in the conventional bi-level error-diffusion halftone method. In this conventional method, an output value Iout is a binary number indicating whether a dot is to be outputted or not. When an input value Iin for one pixel is inputted, values are read from an error buffer 109. The values are errors, which have been obtained at pixels that have been processed previously and that are located near to the subject pixel. A distribution matrix 103 is used to calculate the amount of the portion of the errors, which should be diffused to the present pixel. A corrected input value Iin′ is obtained by adding the portion of the errors to the input value Iin. A comparator 107 compares the corrected input value Iin′ to a threshold read from a threshold memory 105. A dot is outputted when the corrected input value Iin′ is larger than the threshold and not outputted when the corrected input value Iin′ is smaller than the threshold. Next a converter 102 converts the value to 255 when a dot is outputted and to 0 when a dot is not outputted. Next, the difference between the corrected input value Iin′ and the determined value 255 or 0 is stored in the error buffer 109. Because this error diffusion method determines only two levels of gradation per pixel, this method is referred to as a bi-level error-diffusion halftone process.
FIG. 2 is a block diagram showing an overview of processes performed in a multilevel error-diffusion halftone method that determines three or more levels of gradations per pixel by using an error-diffusion process. The multilevel error-diffusion halftone method is employed when a printer used has n levels of gradation per pixel, where n is an integer greater than or equal to three (3). The method shown in this block diagram is for determining four levels per pixel. In order from the level of greatest density, these four levels include large dots, medium dots, small dots, and non-dots. Accordingly, the output Iout obtained by this method will be one of four values: that is, values indicative of “output large dot”, “output medium dot”, “output small dot”, and “output no dot”.
As shown in FIG. 2, the multilevel error-diffusion halftone method is different from the bi-level error-diffusion halftone method in the two points described below:
First, the threshold memory 105 stores therein three thresholds Ta, Tb, and Tc (where Ta>Tb>Tc).
Secondly, a relative density table 112 is additionally provided. The relative density table 112 stores therein four different relative density values in correspondence with the four different values of outputs Iout (values indicative of “output large dot”, “Output medium dot”, “output small dot”, and “output no dot”).
When the input value Iin for one pixel is inputted, the error value's, obtained at the previously processed pixels, are read from the error buffer 109, and the distribution matrix 103 is used to calculate the error for the present pixel. A corrected input value Iin′ is then obtained by adding the error to the input value Iin. The comparator 107 compares the corrected input value Iin′ to each of the three thresholds Ta, Tb, and Tc, which are read from the threshold memory 105. When comparing the corrected input value Iin′ to the three thresholds Ta, Th, Tc, the comparator 107 outputs: an output value Iout indicative of “output large dot” when the corrected input value Iin′ is greater than the threshold Ta; an output value Iout indicative of “output medium dot” when the corrected input value Iin′ is greater than threshold Tb but smaller than threshold Ta; an output value Iout indicative of “output small dot” when the corrected input value Iin′ is greater than threshold Tc but smaller than threshold Tb; and an output value Iout indicative of “output no dot” when the corrected input value Iin′ is smaller than threshold Tc. Next, the converter 102 selects one relative value from the relative value table 112, based on whether the output is a large dot, medium dot, small dot, or no dot. The converter 102 then converts the output value Iout into the selected relative value R. The difference between the corrected input value Iin′ and the relative value R is recorded in the error buffer 109 as an error for the present pixel.